<?php
class ModelCatalogKeeps extends Model {
	/**
	 * 根据用户得到我的保管物品
	 * @param unknown_type $customer_id
	 */
	public function getKeepsByCustomer($customer_id){
		$sql = 
			"SELECT pd.product_id,kp.keeplace_name FROM ".DB_PREFIX."product pd ".
			"LEFT JOIN keeplace kp ON pd.keeplace_id = kp.keeplace_id ".
			"WHERE pd.keeper_id = '".(int)$customer_id."'";
		
		
		$query = $this->db->query($sql);
		return $query->rows;
	}
}